//
//  SheetModel.swift
//  Exchange
//
//  Created by 孟祥群 on 2018/4/28.
//  Copyright © 2018年 common. All rights reserved.
//

import UIKit

class SheetModel: NSObject {
    var curretnStr:String? //选中的文字 传递回来进行匹配
    var titleArr:Array<String> = []
    var selectStr:String? //选中的文字

    var style:sheetStyle?
    var selectIndex:Int = 0
    
    var targetCoin:String = "" //交易币种
    var sourceCoin:String = ""//目标币种
    var isBuyBool:Bool = true //买入
    var orderType:String = "全部" //订单类型
    var orderStates:String = "全部" //订单状态
    
    init(style:sheetStyle) {
        super.init()
        self.style = style
        
    }

}
class CommonSheetModel: SheetModel {
    override init(style: sheetStyle) {
        super.init(style: style)
    }

}
class SelectionModel: SheetModel {
    var leverSheetArr:Array<Array<SheetStyleModel>> = []
    override init(style: sheetStyle) {
        super.init(style: style)
        if style == .leverSelectStyle {
            leverSheetArr = SheetStyleModel .changeModel(style: .leverSelectStyle)
        }else if style == .selectionStyle {
            leverSheetArr = SheetStyleModel .changeModel(style: .selectionStyle)
        }
    }
}
class CapitalModel: SheetModel {
    override init(style: sheetStyle) {
        super.init(style: style)
        if style == .capitalAllStyle {
            self.titleArr = KCapitalAllDataArr
        }else if style == .capitalStyle {
            self.titleArr = KCapitalDataArr
        }
    }
    
}
class LeverCapitalModel: SheetModel {
    var gavelockSheetArr:Array<Array<LeverSheetModel>> = []
    var gavelockLimtArr:Array<Array<LeverSheetModel>> = []
    var model:LeverDataModel = LeverDataModel()
    var isMarketBool:Bool = true
    override init(style: sheetStyle) {
        super.init(style: style)
        gavelockSheetArr = LeverSheetModel.changeModel(marktBool: true)
        gavelockLimtArr = LeverSheetModel.changeModel(marktBool: false)
    }
}

